package com.jt.aop;

import com.jt.vo.SysResult;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.RestControllerAdvice;

/**
 * @Title
 * @Author Peihan.Zhang
 * @Email zhangpeihan@sjgtw.com
 * @Date 2021/11/8 22:46
 * @Versions 1.0
 */

@RestControllerAdvice
public class ExceoptionAop {


    @ExceptionHandler({RuntimeException.class})
    public  Object exception( Exception e){
        e.printStackTrace();
        return SysResult.fail();


    }

}
